# Fernando Rivera

# The idea behind my program is not complex, but it's effectiveness lies in its
# simplicity. My program works off the assumption that the other players as a whole
# are more likley to hunt with a player that has a higher reputation than with one
# that has a lower one. Therefore, there is a tradeoff between a momentary gain
# of food, and reputation in the long term.
# 
# If you consider a game that has been played out by an algorithm, and all of the times
# that it hunted, of all the ways to distribute those hunts, there is one way that will 
# maximize your average reputation for the whole game - playing all the hunts as the
# first rounds.
#
# Now, having this strategy decided it only remains to decide how many hunts should
# be implemented. For this program it was decided to hunt either until some player
# dies or until 350 round have passed, whichever comes first.


class BasePlayer(object):
	
	def __str__(self):
		try:
			return self.name
		except AttributeError:
			return super(BasePlayer, self).__repr__()

	def hunt_choices(*args, **kwargs):
		raise NotImplementedError("No strategy has been implemented")

	def hunt_outcomes(*args, **kwargs):
		pass

	def round_end(*args, **kwargs):
		pass

class Player(BasePlayer):
	
	def __init__(self):
		self.name = "Fernando"
		self.slack = False
		self.numPlayers = 0

	def hunt_choices(
			self,
			round_number,
			current_food,
			current_reputation,
			m,
			player_reputations,
			):

		if round_number == 1:
			self.numPlayers = len(player_reputations)
		if round_number >= 350:
			self.slack = True
		if self.numPlayers > len(player_reputations):
			self.slack = True

		if self.slack:
			return ['s']*len(player_reputations)
		else:
			return ['h']*len(player_reputations)

		
		 

	def hunt_outcomes(self, food_earnings):
		pass

	def round_end(self, award, m, number_hunters):
		pass
		
